import { COMPONENT_TYPE } from '../../constants'

/**
 * @author xuyh0817
 * @email xuyh0817@foxmail.com
 * @date 2022-03-20 01:48
 * @version 2.0.0
 * @doc todo
 * @website todo
 * @remark  如果要分发源码，需在本文件顶部保留此文件头信息！！
 */
export default [
  {
    id: '1',
    type: COMPONENT_TYPE.INPUT_NUMBER,
    formItem: {
      prop: 'current',
      rules: [],
      label: '当前步骤',
      extra: '指定当前步骤，从 0 开始记数',
    },
    attrs: {
      value: 0,
      placeholder: '请输入步骤值'
    }
  },
  {
    id: '2',
    type: COMPONENT_TYPE.RADIO_BUTTON,
    formItem: {
      prop: 'type',
      rules: [],
      label: '类型',
      extra: '步骤条类型，有 default 和 navigation 两种',
    },
    attrs: {
      value: 'default',
      buttonStyle: 'solid',
      children: [
        {
          value: 'default',
          label: 'default'
        },
        {
          value: 'navigation',
          label: 'navigation'
        }
      ]
    }
  },
  {
    id: '3',
    type: COMPONENT_TYPE.RADIO_BUTTON,
    formItem: {
      prop: 'direction',
      rules: [],
      label: '方向',
      extra: '指定步骤条方向。目前支持水平（horizontal）和竖直（vertical）两种方向',
    },
    attrs: {
      value: 'horizontal',
      buttonStyle: 'solid',
      children: [
        {
          value: 'horizontal',
          label: 'horizontal'
        },
        {
          value: 'vertical',
          label: 'vertical'
        }
      ]
    }
  },
  {
    id: '4',
    type: COMPONENT_TYPE.RADIO_BUTTON,
    formItem: {
      prop: 'labelPlacement',
      rules: [],
      label: '标签放置',
      extra: '指定标签放置位置，默认水平放图标右侧，可选vertical放图标下方',
    },
    attrs: {
      value: 'horizontal',
      buttonStyle: 'solid',
      children: [
        {
          value: 'horizontal',
          label: 'horizontal'
        },
        {
          value: 'vertical',
          label: 'vertical'
        }
      ]
    }
  },
  {
    id: '5',
    type: COMPONENT_TYPE.SWITCH,
    formItem: {
      prop: 'progressDot',
      rules: [],
      label: '点状步骤条',
      extra: '可以设置为一个 作用域插槽,labelPlacement 将强制为vertical',
    },
    attrs: {
      checked: false
    }
  },
  {
    id: '6',
    type: COMPONENT_TYPE.RADIO_BUTTON,
    formItem: {
      prop: 'size',
      rules: [],
      label: '大小',
      extra: '目前支持普通（default）和迷你（small）',
    },
    attrs: {
      value: 'default',
      buttonStyle: 'solid',
      children: [
        {
          value: 'default',
          label: 'default'
        },
        {
          value: 'small',
          label: 'small'
        }
      ]
    }
  },
  {
    id: '7',
    type: COMPONENT_TYPE.INPUT_BUTTON,
    formItem: {
      prop: 'children',
      rules: [],
      label: '名称',
      extra: '',
      labelCol: {
        span: 4,
        offset: 0
      },
      wrapperCol: {
        span: 20,
        offset: 0
      }
    },
    attrs: {
      grid: 'row',
      value: [{ code: 'test', title: '测试' }],
      count: 5,
      keys: 'code,title,description,icon,status',
      placeholders: '请输入编码,请输入标题,请输入描述,请输入图标,状态wait|process|finish|error',
      type: 'text',
      allowClear: true
    }
  },
  {
    id: '8',
    type: COMPONENT_TYPE.INPUT,
    formItem: {
      prop: 'layoutName',
      rules: [],
      label: '组件名称',
      extra: '在使用插槽时方，用于标识当前组件',
    },
    attrs: {
      value: Date.now() + '',
      maxLength: 100,
      type: 'text',
      allowClear: true,
      placeholder: '请输入组件名称'
    }
  }
]
